// pages/notify/index.ts
Page({
  data: {
    notifyDetail: null,
  },

  onLoad(params) {
    // console.log(params)
    this.getNotifyDetail(params.id)
  },

  async getNotifyDetail(id) {
    const { code, data } = await wx.http.get(`/announcement/${id}`)
    if (code !== 10000) return wx.utils.toast()
    console.log(data)
    this.setData({
      notifyDetail: data,
    })
  },
})
